package com.neouton.crm.managerPayRequest.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.neouton.common.util.PageUtil;
import com.neouton.crm.entity.SysUserEntity;
import com.neouton.crm.managerPayRequest.entity.ManagerPayRequest;
import com.neouton.crm.managerPayRequest.entity.ManagerPaymentTable;

import javax.servlet.http.HttpServletResponse;
import java.util.List;

public interface ManagerPayRequestService {


    PageUtil<ManagerPayRequest> queryManagerPayRequestList(IPage<ManagerPayRequest> page, ManagerPayRequest paymentRequest, List<SysUserEntity> userList, String token);

    ManagerPayRequest saveManagerPayRequest(ManagerPayRequest managerPayRequest, String token);

    List<ManagerPayRequest> queryManagerPayRequestMoney(ManagerPayRequest managerPayRequest);

    boolean rejectionManagerPayRequest(ManagerPayRequest entity, String token);

    boolean approvedManagerPayRequest(ManagerPayRequest entity, String token, boolean auto);

    ManagerPayRequest queryManagerPayRequestHistory(Integer approvalId);

    void updatePayedRecordTableData(Integer approvalId);

    List<ManagerPayRequest> queryPaymentRequestListInfo(ManagerPayRequest entity, List<SysUserEntity> userList, String token);

    void exportPaymentRequestInfo(HttpServletResponse response, List<ManagerPayRequest> list, String token) throws Exception;

    PageUtil<ManagerPayRequest> queryManagerPayRequestApprovalList(IPage<ManagerPayRequest> page, ManagerPayRequest managerPayRequest, String token);

    List<ManagerPaymentTable> queryPayTablesByIdAndPlanPeriod(ManagerPaymentTable entity);

    Boolean deletePayedRequestById(Integer payRequestId);

    void updatePrIsNotById(Integer payRequestId);
}
